﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class registrazione : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void BInvia_Click(object sender, EventArgs e)
    {
        if (TBUname.Text != "" && TBCognome.Text != "" && TBNome.Text != "" && TBpass.Text != "" && TBEmail.Text != "")
        {
            DB.insertWithOutPar("ForumDB", "insert into userForum(username, password, name, surname, email, avatar) values ('" + TBUname.Text + "','" + TBpass.Text + "','" + TBNome.Text + "','" + TBCognome.Text + "','" + TBEmail.Text + "','/FORUMDEFINITIVO/img/profili/default.jpg')");
            Lris.Text = "Utente registrato con successo";
            Lris.Visible = true;
        }
        else {
            Lris.Text = "Utente non registrato";
            Lris.Visible = true;
        }
    }
}